package com.ruoyi.system.service;

import com.ruoyi.system.domain.SysUserPosition;
import com.ruoyi.system.domain.SysUserPositionLevelHistory;
import org.apache.ibatis.annotations.Param;

import java.util.Date;
import java.util.List;

public interface ISysUserPositionLevelHistoryService {
    /**
     * @param positionId
     * @param userId
     * @param nowDate
     * @return
     */
    public int insertUserPositionLevelByUserId(Long positionId, Long userId, Date nowDate);

    /**
     * 获取给定月份的所有用户岗位信息
     *
     * @param nowDate
     * @return
     */
    public List<SysUserPositionLevelHistory> getPositionsListByNowDate(Date nowDate);

    /**
     * 获取给定月份的用户岗位信息
     *
     * @param userId
     * @param nowDate
     * @return
     */
    public SysUserPositionLevelHistory getPositionsByUserIdAndNowDate(Long userId, Date nowDate);

    /**
     * 触发岗位更新
     * @param positionId
     * @param userId
     * @param nowDate
     * @return
     */

    public int insertOrUpdateUserPositionHistoryByUserId(Long positionId, Long userId, Date nowDate);
}
